package web;

import java.util.Collection;

import javax.faces.model.SelectItem;

import dto.LieuVO;
import dto.VoyageVO;

public class VoyageJsfBean {

	GestionVente gestionVente;

	public void setGestionVente(GestionVente gestionVente) {
		this.gestionVente = gestionVente;
	}

	private Collection<VoyageVO> listeVoyages;
	private String message;

	public String doRecupVoyagesAll() {
		String suite = null;
		try {
//			listeVoyages = new java.util.ArrayList<VoyageVO>();
//			VoyageVO v;
//			v = new VoyageVO(); v.setDestination(new LieuVO("simu1")); listeVoyages.add(v);
//			v = new VoyageVO(); v.setDestination(new LieuVO("simu2")); listeVoyages.add(v);
			this.listeVoyages = gestionVente.getAllVoyages();
			suite = "ok";
		} catch (Exception e) {
			e.printStackTrace();
		}
		return suite;
	}
	
	public Collection<VoyageVO> getListeVoyages() {
		return listeVoyages;
	}
	public void setListeVoyages(Collection<VoyageVO> listeVoyages) {
		this.listeVoyages = listeVoyages;
	}

	public String getMessage() {
		return message;
	}

}
